package com.ktjy.springsecuritydemo.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
public class LoginController {
    @GetMapping("/tologin")
    public String toLogin(){
        return "login";
    }

//    @PostMapping("doLogin")
//    public String login(){
//        System.out.println("执行登录方法");
//        return "main";
//    }

    @RequestMapping("/toMain")
    public String toMain(){
        return "main";
    }
}
